From f763df82e290c189643781917b90081b6d01d102 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20H=C3=A4rdeman?= Date: Thu, 23 Oct 2025 19:18:13 +0200 Subject: [PATCH] luci-mod-network: rename advanced tab MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Move the remaining three options to the general tab, mark two of them as dnsmasq-only. Signed-off-by: David Härdeman --- .../resources/view/network/interfaces.js | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js b/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js index d242324bbf..e4a7a72297 100644 --- a/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js +++ b/modules/luci-mod-network/htdocs/luci-static/resources/view/network/interfaces.js @@ -668,7 +668,6 @@ return view.extend({ ss.anonymous = true; ss.tab('general', _('General Setup')); - ss.tab('advanced', _('Advanced Settings')); ss.tab('ipv4', _('IPv4 Settings')); ss.tab('ipv6', _('IPv6 Settings')); ss.tab('ipv6-ra', _('IPv6 RA Settings')); @@ -743,10 +742,13 @@ return view.extend({ return _("Invalid DHCP lease time format. Use integer values optionally followed by s, m, h, d, or w."); } - so = ss.taboption('advanced', form.Flag, 'dynamicdhcp', _('Dynamic DHCP'), _('Dynamically allocate DHCP addresses for clients. If disabled, only clients having static leases will be served.')); + so = ss.taboption('general', form.Flag, 'dynamicdhcp', _('Dynamic DHCP'), _('Dynamically allocate DHCP addresses for clients. If disabled, only clients having static leases will be served.')); so.default = so.enabled; - ss.taboption('advanced', form.Flag, 'force', _('Force'), _('Force DHCP on this network even if another server is detected.')); + if (L.hasSystemFeature('dnsmasq')) { + ss.taboption('general', form.Flag, 'force', _('Force'), + _('Force DHCP on this network even if another server is detected (dnsmasq only).')); + } // XXX: is this actually useful? //ss.taboption('advanced', form.Value, 'name', _('Name'), _('Define a name for this network.')); @@ -768,7 +770,10 @@ return view.extend({ }; } - ss.taboption('advanced', form.DynamicList, 'dhcp_option', _('DHCP-Options'), _('Define additional DHCP options, for example "6,192.168.2.1,192.168.2.2" which advertises different DNS servers to clients.')); + if (L.hasSystemFeature('dnsmasq')) { + ss.taboption('general', form.DynamicList, 'dhcp_option', _('DHCP-Options'), + _('Define additional DHCP options, for example "6,192.168.2.1,192.168.2.2" which advertises different DNS servers to clients (dnsmasq only).')); + } } -- 2.30.2